<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<Netkk.Models.MessageModel>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <title>E-Mail senden - .NET-Stammtisch Konstanz-Kreuzlingen</title>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <h1>
        E-Mail senden</h1>
    <%= Html.ValidationSummary() %>
    <%using (Html.BeginForm("Email", "Contact", FormMethod.Post, new Dictionary<string, object> { { "name", "mainform" } }))
      { %>
    <dl class="forms">
        <dt>
            <label for="ToUser">
                An:</label></dt>
        <dd>
            <%=Html.TextBox("ToUser", Model.ToUser.ToString(), new Dictionary<string, object> { { "class", "readonly" }, { "readonly", "readonly" } })%>
            <%=Html.ValidationMessage("ToUser", "*")%></dd>
        <dt>
            <label for="Name">
                Name:</label></dt>
        <dd>
            <%=Html.TextBox("Name", Model.FromUser.ToString(), new Dictionary<string, object> { { "class", "readonly" }, { "readonly", "readonly" } })%>
            <%=Html.ValidationMessage("Name", "*")%>
        </dd>
        <dt>
            <label for="Email">
                Email:</label></dt>
        <dd>
            <%=Html.TextBox("Email", Model.FromUser.Email, new Dictionary<string, object> { { "class", "readonly" }, { "readonly", "readonly" } })%>
            <%=Html.ValidationMessage("Email", "*")%>
        </dd>
        <dt>
            <label for="Subject">
                Betreff:</label></dt>
        <dd>
            <%=Html.TextBox("Subject", Model.Subject, new Dictionary<string, object> { { "class", "withhint" }, { "title", "Geben Sie hier Ihren Betreff ein.\nDiese Angabe ist nicht optional." } })%>
            <%=Html.ValidationMessage("Subject", "*")%>
        </dd>
        <dt class="ta">
            <label for="Text">
                Ihre Nachricht:</label></dt>
        <dd class="ta">
            <%=Html.TextArea("Text", Model.Text, new Dictionary<string, object> { { "class", "withhint" }, { "title", "Geben Sie hier eine Nachrictentext.\nDiese Angabe ist nicht optional." } })%>
            <%=Html.ValidationMessage("Text", "*")%>
        </dd>
        <dt></dt>
        <dd>
            <a href="javascript:void(0);" onclick="document.forms['mainform'].submit();" class="send button">
                <span>Versenden</span></a></dd>
    </dl>
    <% }%>

    <script type="text/javascript">
        $(document).ready(function()
        {
            $('#Text').wysiwyg();
        });
    </script>

</asp:Content>
